﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="DocumentManagement.Views.NeedToCharge" %>

<%@ Import Namespace="DocumentManagement.Models" %>
<asp:Content ID="Content1" ContentPlaceHolderID="MainContent" runat="server">
    <h2>
        分派报告去收费</h2>
    <table>
        <tr>
            <td>
                文件编号
            </td>
            <td>
                委托来源
            </td>
            <td>
                委托方
            </td>
            <td>
                项目座落
            </td>
            <td>
                报告状态
            </td>
            <td>
                评估总价
            </td>
            <td>
                评估单价
            </td>
            <td>
                估价作业人员
            </td>
            <td>
                评估完成日期
            </td>
            <td>
                报告附件
            </td>
            <td>
                相关联的预估单
            </td>
            <td>
                开票金额
            </td>
            <td>
                发票编号
            </td>
            <td>人员</td>
            <td></td>
        </tr>
        <%foreach (var bg in this.Model.BGs)
          { %>
        <tr>
            <%using (this.Html.BeginForm("AssginBaoGaoToChargeMoney", "baogao", FormMethod.Post))
              {%>
            <td>
                <a target="_blank" href="<%=this.Url.Action("ShowBaoGaoDetail", "baogao", new {id = bg.id}) %>">
                    <%=bg.wjbh%>
                </a>
                <input type="hidden" value="<%=bg.id %>" name="id"/>
            </td>
            <td>
                <%=bg.wtly%>
            </td>
            <td>
                <%=bg.wtf%>
            </td>
            <td>
                <%=bg.xmzl%>
            </td>
            <td>
                <%=Utility.GetEnumText((BaoGaoState)bg.state)%>
            </td>
            <td>
                <%=bg.pgzj%>
            </td>
            <td>
                <%=bg.pgdj%>
            </td>
            <td>
                <%=bg.gjzyry%>
            </td>
            <td>
                <%=bg.pgwchrq%>
            </td>
            <td>
                <%if (bg.hasAttachment)
                  { %>
                <a href="<%=this.Url.Action("DownloadBaoGaoAttachment", "BaoGao", new {id= bg.id})%>">
                    附件</a>
                <%} %>
            </td>
            <td>
            <%if (bg.YuGuDanReference.EntityKey != null)
              { %>
                <a target="_blank" href="<%=this.Url.Action("ShowYuGuDanDetail", "yugudan", new {id = bg.YuGuDanReference.EntityKey.GetKeyValueByName("id")}) %>">
                    <%=bg.YuGuDanReference.EntityKey.GetKeyValueByName("id")%>
                </a>
            <%} %>
            </td>
            <td>
                <input type="text" name="kpje" />
            </td>
            <td>
                <input type="text" name="fpbh" />
            </td>
            <td>
                <%=this.Html.DropDownList("assigneeId", GetEmployeeDropList())%>
            </td>
            <td>
                <input type="submit" value="分派去收费" />
            </td>
            <%} %>
        </tr>
        <%}%>
    </table>
</asp:Content>
